import request from '../utils/request.js';
import request_sh from '../utils/request_sh.js';
import request2 from '../utils/request2.js';
//查询订单
export function getOrders(data){
	return request({
		url:'/WX3SalesOrder?grant_type=wechat_program',
		method:'POST',
		data,
	})
}
//查询订单
export function getWeChatSalesOrder(data){
	return request({
		url:'/getWeChatSalesOrder?grant_type=wechat_program',
		method:'POST',
		data,
	})
}

// 再来一单
export function getOneOrder(data){
	return request({
		url:'/WXCheckSaleOrderAgainAction?grant_type=wechat_program',
		method:'POST',
		data,
	})
}
// 退款
export function getRefund(data){
	return request({
		url:'/WXWeChatRefundNativeAction?grant_type=wechat_program',
		method:'POST',
		data,
	})
}
export function getWeChatRefundAction(data){
	return request({
		url:'/getWeChatRefundAction?grant_type=wechat_program',
		method:'POST',
		data,
	})
}
// 获取退款明细
export function getRefundDetails(data){
	return request({
		url:'/WeChatRefundDetailAction?grant_type=wechat_program',
		method:'POST',
		data,
	})
}
// 取消订单
export function getCancelOrder(data){
	return request({
		url:'/WXCancelOrder?grant_type=wechat_program',
		method:'POST',
		data,
	})
}
// 撤销申请退款
export function getQuash(data){
	return request({
		url:'/NoClientRefund?grant_type=wechat_program',
		method:'POST',
		data,
	})
}
// 查询订单数量红点
export function getChatOrder(data){
	return request({
		url:'/WeChatOrderType?grant_type=wechat_program',
		method:'POST',
		data,
	})
}

export function getRefundType(data){
	return request_sh({
		url:'/Order/getOrderRefundStatus',
		method:'GET',
		data,
	})
}